import 'package:json_annotation/json_annotation.dart';
part 'info_item.g.dart';

@JsonSerializable()
class InfoItem {
  final String id;
  final String title;
  final String imageUri;
  final String source;
  final String time;
  final String navigateUri;

  const InfoItem(
      {this.id,
      this.title,
      this.imageUri,
      this.source,
      this.time,
      this.navigateUri});
  factory InfoItem.fromJson(Map<String, dynamic> json) =>
      _$InfoItemFromJson(json);

  Map<String, dynamic> toJson(InfoItem instance) => _$InfoItemToJson(this);
}
//半自动化
//执行命令 flutter packages pub run build_runner build
